#ifndef _DOMINION_HELPERS_H
#define _DOMINION_HELPERS_H

#include "dominion.h"

int drawCard(int player, struct gameState *state);
int updateCoins(int player, struct gameState *state, int bonus);
int discardCard(int handPos, int currentPlayer, struct gameState *state,
                int trashFlag);
int gainCard(int supplyPos, struct gameState *state, int toFlag, int player);
int getCost(int cardNumber);
int cardEffect(int card, int choice1, int choice2, int choice3,
               struct gameState *state, int handPos, int *bonus);

// Testing helper functions
void fill_array(int *s, int v, size_t n);
int ops_hand_counts(int player, struct gameState *state);
int ops_deck_counts(int player, struct gameState *state);
int ops_discard_counts(int player, struct gameState *state);
void replace_card(int player, struct gameState *state, int from, int to);
int count_in_hand(int player, struct gameState *state, int card);
int randRange(int lhs, int rhs);
int randCard(void);
int numersort(const void *lhs, const void *rhs);
int compare_cards(int *to, int to_count, int *from, int from_count);

#endif
